﻿//
// File:    ConView.cs
// Project: MP3 Art Embedder v0.2.x
//
// This program is a console equivalent of the GUI MP3 Art Embedder. Its
// purpose is primarily to serve as a sort of proof-of-architecture.

using System;
using Mp3LibraryViewed;
using ConController;

namespace ConView
{
    internal class AppViewFactory : IAppViewFactory
    {
        public void Make (AppController controller, Mp3LibraryModelBase modelBase)
        {
            var view = new AppView (controller, modelBase);
        }
    }


    internal class AppView
    {
        class Program
        {
            // See usage output in Controller for possible args.
            static int Main (string[] args)
            {
                var controller = new AppController (args, new AppViewFactory());
                return controller.Run();
            }
        }


        public AppView (AppController controller, Mp3LibraryModelBase modelBase)
        {
            modelBase.ActionLogged += Logger;
        }


        private void Logger (string message, Strength strength)
        {
            Console.WriteLine (message);
        }
    }
}
